<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:a="http://richfaces.org/a4j"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:rg="http://www.ruijie.com.cn/faces/ui"
	template="/layout/dialogLayout.xhtml">

	<ui:param name="param_panelTitle" value="赠送会员积分" />
	<ui:param name="param_panelWidth" value="540px" />

	<ui:define name="content">
		<h:form id="orderShip">
			<rg:titlePanel  type="writable" needButton="true">
				<ui:define name="panelBody">
					<rg:fieldSet>
						<rg:inputText id="integral"
							value="#{holidaySalesAction.integral}" label="赠送积分" />
						<rg:inputArea label="短信发送内容"
							value="#{holidaySalesAction.sms}"
							id="sms" textStyle="width:320px;height:120px"/>
						<rg:inputArea label="积分赠送原因"
							value="#{holidaySalesAction.remark}"
							id="remark" textStyle="width:320px;height:120px"/>
					</rg:fieldSet>

					<a:jsFunction id="bestowIntegral" name="bestowIntegral" action="#{ansyAction.pollAsynSupport(holidaySalesSupport)}" 
						onbeforedomupdate="UI.instance.showMask();" actionListener="#{holidaySalesAction.bestowIntegral}" 
						oncomplete="UI.instance.showDialog({id:'ansy_bestowIntegral', closable:false, src:'/layout/dialog/asyn.jsf', title: '积分赠送'})"/>	
					<rg:tipMessage tipMessage="短信发送内容中" tipMessage2="使用‘ #{'#'}{会员姓名} ’会发送短信时替换成实际的会员姓名"
					 		tipMessage3="使用‘ #{'#'}{赠送积分} ’会发送短信时替换成实际的赠送积分"
				  			tipMessage4="使用‘ #{'#'}{会员积分} ’会发送短信时替换成实际的会员积分(加过积分后)" />
				</ui:define>
				<ui:define name="panelButton">
					<input class="button" type="button"
						value="赠送积分" onclick="bestowIntegral();" />
					<a:commandButton styleClass="button" value="关闭"
						onclick="UI.instance.closeDialog()" />
				</ui:define>
			</rg:titlePanel>
		</h:form>
	</ui:define>
</ui:composition>
